#include"string.h"


/*int main()
{
	//My::string s("xiao");
	//cout << s.c_str() << endl;

	//cout << s[2] << endl;

	//for (size_t i = 0; i < s.size(); i++)
	//{
	//	cout << s[i] << ' ';
	//}
	//cout << endl;
	////My::string::iterator it = s.begin();
	//auto it = s.begin();
	//while (it !=s.end( ))
	//{
	//	cout << *it << " ";
	//	++it;
	//}
	//cout << endl;
	//for (auto ch: s)
	//{
	//	cout << ch << " ";
	//}
	/*string s("xiao");
	cout << s.c_str() << endl;
	s.push_back('*');
	s.push_back('*');
	cout << s.c_str() << endl;
	s.append("%%");
	cout << s.c_str() << endl;
	s += '0';
	s += "@@@";
	cout << s.c_str() << endl;

	My::string s1("hello world");
	cout << s1.c_str() << endl;
	cout << s1.size() << endl;
	cout << s1.capacity() << endl;
	s1 += 'x';
	s1 += '#';
	s1 += "hello bit";
	cout << s1.c_str() << endl;

	s1.insert(5, '6');
	cout << s1.c_str() << endl;

	s1.insert(2, "$$");
	cout << s1.c_str() << endl;
	s1.insert(0,' ');
	cout << s1.c_str() << endl;
	s1.erase(0, 1);
	cout << s1.c_str() << endl;
	s1.erase(0);
	cout << s1.c_str() << endl;
	cout <<"xxx" << endl;

	My::string ss("xiao.txt");
	size_t pos = ss.find('.');
	My::string suff = ss.substr(pos);
	cout << suff.c_str() << endl;
	s1 = ss;
	cout << ss.c_str() << endl;
	cout << s1.c_str() << endl;

	ss = ss;
	//cout << ss.c_str() << endl;
	cout << ss << endl;

	cin >> ss;
	cout << ss << endl;
	return 0;
}*/

namespace My
{
	void text()
	{
		string s;
		//cin >> s;
		//cout << s ;
		getline(cin,s);
		
		cout << s << endl;

	}

	void text1()
	{
		string ss;

		cout << ss << endl;
		string s = ss;
		cout << s << endl;

		string sss("xxxxxxxxxxx");
		s = sss;
		cout << sss << endl;
		cout << s << endl;

	}
} 

#include <string>

int main()
{
	//My::text1();
	//My::text();

	/*std::string s1("xxxxxxxxxxxxx");
	std::string s2(s1);
	printf("%p\n", s1.c_str());
	printf("%p\n", s2.c_str());

	s2[0] = '*';
	printf("%p\n", s1.c_str());
	printf("%p\n", s2.c_str());*/

	string s = to_string(9203);
	string s1 = to_string(2.14);
	string s2 = to_string(888.222);
	cout << s << endl;
	cout << s1 << endl;
	cout << s2 << endl;

	

	return 0;
}